<!--
 *
 * FaZend Framework
 *
 * This source file is subject to the new BSD license that is bundled
 * with this package in the file LICENSE.txt. It is also available 
 * through the world-wide-web at this URL: http://www.fazend.com/license
 * If you did not receive a copy of the license and are unable to
 * obtain it through the world-wide-web, please send an email
 * to license@fazend.com so we can send you a copy immediately.
 *
-->

<li>
<b><?php echo $this->label?></b> 
    <a href="<?php 
    echo $this->url(
        array(
            'action'=>'pos', 
            'object'=>$this->node->ps()->id
        ), 
        'adm', 
        true
    )?>">v<?php echo $this->node->ps()->version?></a>: 
    <?php echo $this->node->ps()->type?>

<ul>
<?php foreach ($this->node->ps()->properties as $name): ?>
    <?php if (substr($name, 0, strlen(FaZend_Pos_Properties::ARRAY_PREFIX)) == FaZend_Pos_Properties::ARRAY_PREFIX): ?>
        <?php $label = '[' . substr($name, strlen(FaZend_Pos_Properties::ARRAY_PREFIX)) . ']' ?>
    <?php else: ?>
        <?php $label = $name ?>
    <?php endif; ?>
    <?php if ($this->node->$name instanceof FaZend_Pos_Abstract): ?>
        <?php 
        echo $this->partial(
            'adm/pos/node.phtml', 
            array(
                'node' => $this->node->$name,
                'label' => $label
            )
        )?>    
    <?php elseif (is_scalar($this->node->$name)): ?>
        <li><?php echo $label?>: <?php echo $this->node->$name?></li>
    <?php else: ?>
        <li><?php echo $label?>: <?php echo get_class($this->node->$name)?></li>
    <?php endif; ?>
<?php endforeach; ?>
</ul>

</li>